public class Solution {
    public int findLUSlength(String a, String b) {
        if(a.equals(b))
            return -1;
        return a.length() > b.length() ? a.length() : b.length();
    }

    public static void main(String[] args) {
        Solution solution = new Solution();
        String a1 = "aba";
        String b1 = "cdc";
        System.out.println("a = \"" + a1 + "\", b = \"" + b1 + "\"");
        System.out.println("Result: " + solution.findLUSlength(a1, b1)); // 输出较长字符串的长度

    }
}
